//
//  UIButton+Extension.swift
//  weibo_swift
//
//  Created by qiuming on 16/9/18.
//  Copyright © 2016年 qiuming. All rights reserved.
//

import UIKit

extension UIButton {
    
    
    convenience init(imageName: String, backImageName: String) {
        
        self.init()
        
        setImage(UIImage(named: imageName), for: .normal)
        
        setImage(UIImage(named: imageName + "_highlighted"), for: .highlighted)
        
        setBackgroundImage(UIImage(named: backImageName), for: .normal)
        setBackgroundImage(UIImage(named: backImageName + "_highlighted"), for: .highlighted)
        
        sizeToFit()
    }
    
    

    
}
